package com.hjh.gameforum.mapper;

import com.hjh.gameforum.dto.CategoryDto;
import com.hjh.gameforum.entity.Category;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface CategoryMapper {
    void createCategory(Category category);

    List<Category> getAllCategories();

    void updateCategory(Category  category);

    @Delete("DELETE FROM categories WHERE category_id = #{categoryId}")
    void deleteCategory(Long categoryId);
}
